home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2002 November / SGI IRIX Base Documentation 2002 November.iso / usr / share / catman / p_man / cat3 / il / ilProperty.z / ilProperty
Encoding:
Text File  |  2002-10-03  |  5.5 KB  |  133 lines

  1.  
  2.  
  3.  
  4. iiiillllPPPPrrrrooooppppeeeerrrrttttyyyy((((3333))))      IIIImmmmaaaaggggeeeeVVVViiiissssiiiioooonnnn LLLLiiiibbbbrrrraaaarrrryyyy CCCC++++++++ RRRReeeeffffeeeerrrreeeennnncccceeee MMMMaaaannnnuuuuaaaallll      iiiillllPPPPrrrrooooppppeeeerrrrttttyyyy((((3333))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      iiiillllPPPPrrrrooooppppeeeerrrrttttyyyy - name/value pair
  10.  
  11. IIIINNNNHHHHEEEERRRRIIIITTTTSSSS FFFFRRRROOOOMMMM
  12.      - Base class
  13.  
  14. HHHHEEEEAAAADDDDEEEERRRR FFFFIIIILLLLEEEE
  15.      #include <il/ilPropSet.h>
  16.  
  17. CCCCLLLLAAAASSSSSSSS DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  18.      An iiiillllPPPPrrrrooooppppeeeerrrrttttyyyy object is used to associate a name string with a value.  It
  19.      is an element of an iiiillllPPPPrrrrooooppppSSSSeeeetttt object which represents a collection of
  20.      properties.  Any object in the IL that is derived from iiiillllLLLLiiiinnnnkkkk has an
  21.      iiiillllPPPPrrrrooooppppSSSSeeeetttt associated with it and so it is possible to assign and modify
  22.      named properties to such objects.  In most instances, there is no need to
  23.      directly manipulate an iiiillllPPPPrrrrooooppppeeeerrrrttttyyyy object since methods exist to access it
  24.      indirectly through iiiillllPPPPrrrrooooppppSSSSeeeetttt and through iiiillllLLLLiiiinnnnkkkk.  However, it can be
  25.      accessed directly in order to get and set its value and to get its name.
  26.      Its value can be either an integer, a float, or a pointer.  Its name is
  27.      an iiiiffffllllNNNNaaaammmmeeee object.  An iiiillllPPPPrrrrooooppppeeeerrrrttttyyyy object cannot simultaneously be an
  28.      element of more than one iiiillllPPPPrrrrooooppppSSSSeeeetttt object.
  29.  
  30. CCCCLLLLAAAASSSSSSSS MMMMEEEEMMMMBBBBEEEERRRR FFFFUUUUNNNNCCCCTTTTIIIIOOOONNNN SSSSUUUUMMMMMMMMAAAARRRRYYYY
  31.      CCCCoooonnnnssssttttrrrruuuuccccttttoooorrrr
  32.  
  33.           ilProperty(iflName* n, const ilPropValue& v)
  34.  
  35.      GGGGeeeetttt////sssseeeetttt mmmmeeeetttthhhhooooddddssss
  36.  
  37.           void setVal(float f)
  38.           void setVal(int i)
  39.           void setVal(void* p)
  40.           void setVal(const ilPropValue& v)
  41.           float getFloat() const
  42.           int getInt() const
  43.           void* getPtr() const
  44.           iflName* getName() const
  45.  
  46.  
  47. FFFFUUUUNNNNCCCCTTTTIIIIOOOONNNN DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNNSSSS
  48.      iiiillllPPPPrrrrooooppppeeeerrrrttttyyyy(((())))
  49.  
  50.           ilProperty(iflName* n, const ilPropValue& v)
  51.  
  52.  
  53.           Create a new ilProperty object with name specified by _n and value _v.
  54.           The value argument is a reference to an object of type ilPropValue
  55.           which has the following definition:
  56.  
  57.           union ilPropValue {
  58.               ilPropValue(int I) { i = I; }
  59.               ilPropValue(float F) { f = F; }
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. iiiillllPPPPrrrrooooppppeeeerrrrttttyyyy((((3333))))      IIIImmmmaaaaggggeeeeVVVViiiissssiiiioooonnnn LLLLiiiibbbbrrrraaaarrrryyyy CCCC++++++++ RRRReeeeffffeeeerrrreeeennnncccceeee MMMMaaaannnnuuuuaaaallll      iiiillllPPPPrrrrooooppppeeeerrrrttttyyyy((((3333))))
  71.  
  72.  
  73.  
  74.               ilPropValue(void* P) { p = P; }
  75.               ilPropValue(const ilPropValue& V) { *this = V; }
  76.               void* p;
  77.               float f;
  78.               int i;
  79.           };
  80.  
  81.  
  82.      ggggeeeettttFFFFllllooooaaaatttt(((())))
  83.  
  84.           float getFloat() const
  85.  
  86.  
  87.           Return the property value interpreted as a float.
  88.  
  89.      ggggeeeettttIIIInnnntttt(((())))
  90.  
  91.           int getInt() const
  92.  
  93.  
  94.           Return the property value interpreted as an integer.
  95.  
  96.      ggggeeeettttNNNNaaaammmmeeee(((())))
  97.  
  98.           iflName* getName() const
  99.  
  100.  
  101.           Return a pointer to the property name.
  102.  
  103.      ggggeeeettttPPPPttttrrrr(((())))
  104.  
  105.           void* getPtr() const
  106.  
  107.  
  108.           Return the property value interpreted as an pointer.
  109.  
  110.      sssseeeettttVVVVaaaallll(((())))
  111.  
  112.           void setVal(float f)
  113.           void setVal(int i)
  114.           void setVal(void* p)
  115.           void setVal(const ilPropValue& v)
  116.  
  117.  
  118.           Set the value of the property.  This method is overloaded to support
  119.           each of the value types: float, integer, and pointer and also to
  120.           copy another property value.
  121.  
  122. SSSSEEEEEEEE AAAALLLLSSSSOOOO
  123.      ilPropSet, ilPropList, ilPropTable, ilLink, iflName, iflDictionary
  124.  
  125.  
  126.  
  127.  
  128.  
  129.                                                                         PPPPaaaaggggeeee 2222
  130.  
  131.  
  132.  
  133.